<#include "/default/_inc/_head.html"/>
<#include "/default/_inc/_layout2.html"/>
<!DOCTYPE HTML>
<html lang="${lang}">

<head>
    <@head />
</head>

<body id="blog">
    <@layout>
    <div>
        <div class="toppic">
            <div class="am-container-1">

            </div>
        </div>

        <div class="am-container-1 margin-t30">
            <div class="words-title ">
                <span>${article.title}</span>
                <div>${article.createDate?string('yyyy-MM-dd hh:mm:ss')}</div>
            </div>
        </div>

        <div class="solution-inform">
            <div class=" solution-inform-content-all">
                <div class="solution-inform-content">

                </div>
            </div>
        </div>
    </div>
    </@layout>
    <script type="text/javascript">
        var encodeEscape = {
            html2Escape: function (value) {
                var entities = {'<': '&lt;', '>': '&gt;', '&': '&amp;', '"': '&quot;', "'": "&apos;"};
                return value.replace(/[<>&"]/g, function (all) {
                    return entities[all];
                });
            },
            escape2Html: function (value) {
                var entities = {
                    //'&#34': '"',
                    'lt': '<',
                    'gt': '>',
                    'nbsp': ' ',
                    'amp': '&',
                    'quot': '"',
                    'apos': "'",
                    'mdash': '—',
                    'ldquo': '“',
                    'rdquo': '”'
                };
                return value.replace(/&(lt|gt|nbsp|amp|quot|apos|mdash|ldquo|rdquo);/ig, function (all, t) {
                    return entities[t];
                });
            }
        }
        $(function () {
            $.ajax({
                type: "POST",
                data: {},
                dataType: 'json',
                url: '/article/content/${article.articleId}',
                success: function (res) {
                    if (res.success) {
                        var data = res.data;
                        $('.solution-inform-content').html(encodeEscape.escape2Html(data.content));
                    } else {
                        //layer.alert(res.message, {icon: 2});
                    }
                }
            });
        });
    </script>
</body>

</html>